﻿namespace TestTool.Tests.Definitions.Data
{
    using System;
    using System.Collections.Generic;
    using System.Reflection;
    using System.Runtime.CompilerServices;
    using System.Xml.Serialization;
    using TestTool.Tests.Definitions.Enums;

    [Serializable]
    public class TestInfo
    {
        private List<Functionality> _functionalityUnderTest = new List<Functionality>();
        private List<Feature> _requiredFeatures = new List<Feature>();

        public TestInfo()
        {
            this.ProcessType = TestTool.Tests.Definitions.Data.ProcessType.Test;
        }

        public TestTool.Tests.Definitions.Enums.Category Category { get; set; }

        [XmlIgnore]
        public TestExecutionOrder ExecutionOrder { get; set; }

        public List<Functionality> FunctionalityUnderTest
        {
            get
            {
                return this._functionalityUnderTest;
            }
        }

        public string Group { get; set; }

        public string Id { get; set; }

        [XmlIgnore]
        public MethodInfo Method { get; set; }

        public string Name { get; set; }

        [XmlIgnore]
        public string Order { get; set; }

        [XmlIgnore]
        public TestTool.Tests.Definitions.Data.ProcessType ProcessType { get; set; }

        public List<Feature> RequiredFeatures
        {
            get
            {
                return this._requiredFeatures;
            }
        }

        public TestTool.Tests.Definitions.Enums.RequirementLevel RequirementLevel { get; set; }

        [XmlIgnore]
        public double Version { get; set; }
    }
}

